package com.slz3.business.module.wmsManagement.wmsPurchaseOrderLine.steward;

import com.slz3.business.frame.response.RR;
import com.slz3.business.frame.response.ResInfo;
import com.slz3.business.module.wmsManagement.wmsPurchaseOrderLine.domain.WmsPurchaseOrderLine;
import com.slz3.business.module.wmsManagement.wmsPurchaseOrderLine.domain.WmsPurchaseOrderLineCondition;
import org.springframework.stereotype.Component;
import org.springframework.web.reactive.function.server.ServerRequest;
import org.springframework.web.reactive.function.server.ServerResponse;
import reactor.core.publisher.Mono;

public class WmsPurchaseOrderLineResAtomic extends WmsPurchaseOrderLineResExecutor {

    public Mono<ServerResponse> add_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLine wmsPurchaseOrderLine) {
        return WmsPurchaseOrderLineResSafeValid.add(req, wmsPurchaseOrderLine) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.add(req, wmsPurchaseOrderLine);
    }

    public Mono<ServerResponse> delete_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.delete(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.delete(req);
    }

    public Mono<ServerResponse> modify_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLine wmsPurchaseOrderLine) {
        return WmsPurchaseOrderLineResSafeValid.modify(req, wmsPurchaseOrderLine) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.modify(req, wmsPurchaseOrderLine);
    }

    public Mono<ServerResponse> info_$WmsPurchaseOrderLineUpdateLock(ServerRequest req) {
        return WmsPurchaseOrderLineResSafeValid.info(req) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.info(req);
    }

    public Mono<ServerResponse> auditSubmit_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.auditSubmit(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditSubmit(req);
    }

    public Mono<ServerResponse> audit_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.audit(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.audit(req);
    }

    public Mono<ServerResponse> auditReject_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.auditReject(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditReject(req);
    }


    public Mono<ServerResponse> usingEnable_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.usingEnable(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingEnable(req);
    }

    public Mono<ServerResponse> usingDisable_$WmsPurchaseOrderLineUpdateLock(ServerRequest req, WmsPurchaseOrderLineCondition wmsPurchaseOrderLineCondition) {
        return WmsPurchaseOrderLineResSafeValid.usingDisable(req, wmsPurchaseOrderLineCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingDisable(req);
    }
}
